QT       += core gui

greaterThan(QT_MAJOR_VERSION, 4): QT += widgets

CONFIG += c++11
CONFIG += console

# You can make your code fail to compile if it uses deprecated APIs.
# In order to do so, uncomment the following line.
#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000    # disables all the APIs deprecated before Qt 6.0.0

SOURCES += \
    control/durationslider.cpp \
    ffplay/Decoder.cpp \
    ffplay/FFMediaPlayer.cpp \
    ffplay/FFplayerQt.cpp \
    ffplay/FrameQueue.cpp \
    ffplay/PacketQueue.cpp \
    main.cpp \
    ui/mainwidget.cpp \
    utils/TarsThreadPool.cpp \
    utils/utils.cpp

HEADERS += \
    control/durationslider.h \
    ffplay/AudioParams.h \
    ffplay/Decoder.h \
    ffplay/FFMediaPlayer.h \
    ffplay/FFplayerQt.h \
    ffplay/FrameQueue.h \
    ffplay/PacketQueue.h \
    ffplay/ffinc.h \
    ui/mainwidget.h \
    ui/myQSS.h \
    utils/TarsThreadPool.h \
    utils/utils.h

INCLUDEPATH += $$PWD/ui \
               $$PWD/utils \
               $$PWD/control \
               $$PWD/ffplay \
               $$PWD/3rdparty/include/ffmpeg \
               $$PWD/3rdparty/include/SDL2

LIBS += $$PWD/3rdparty/lib/ffmpeg/avformat.lib   \
        $$PWD/3rdparty/lib/ffmpeg/avcodec.lib    \
        $$PWD/3rdparty/lib/ffmpeg/avdevice.lib   \
        $$PWD/3rdparty/lib/ffmpeg/avfilter.lib   \
        $$PWD/3rdparty/lib/ffmpeg/avutil.lib     \
        $$PWD/3rdparty/lib/ffmpeg/postproc.lib   \
        $$PWD/3rdparty/lib/ffmpeg/swresample.lib \
        $$PWD/3rdparty/lib/ffmpeg/swscale.lib    \
        $$PWD/3rdparty/lib/SDL2/SDL2.lib

# Default rules for deployment.
qnx: target.path = /tmp/$${TARGET}/bin
else: unix:!android: target.path = /opt/$${TARGET}/bin
!isEmpty(target.path): INSTALLS += target

RESOURCES += \
    res.qrc
